import { request } from "../../public/js/requist.js";
Page({
  
  data:{
    //存储轮播图数据
    swiperData:[],
    //存储导航数据
    NavData:[],
    //存储楼层数据
    floordata:[]
  },
  onLoad(){
    //轮播图
   request('/home/swiperdata').then(result => {
     let swiperData = result.data.message
     this.setData({
      swiperData
     })
   })

   //导航栏
   request('/home/catitems').then(result => {
     let NavData = result.data.message
     this.setData({
      NavData
     })
   })

   //楼层数据
   request('/home/floordata').then(result => {
      console.log(result.data.message);
      let floordata = result.data.message

      this.setData({
        floordata
      })
   })
  }
})